Skip to content

fix(flags): don't match person_metadata filters against person properties - #1288

Open
srednoff888-art wants to merge 4 commits into
PostHog:mainfrom
srednoff888-art:fix/person-metadata-filters
Open

srednoff888-art wants to merge 4 commits into
PostHog:mainfrom
srednoff888-art:fix/person-metadata-filters

Conversation

@srednoff888-art

@srednoff888-art srednoff888-art commented Nov 21, 2026 •

Copy link
Copy Markdown

💡 Motivation and Context

Part of PostHog/posthog#137503, for posthog-python, where the issue was reproduced.

A cohort can filter on Person metadata > First seen: {"type": "person_metadata", "key": "created_at", ...}. /flags reads that value from the persons table and ignores any created_at person property. Local evaluation treated every filter type other than cohort and flag as a person property, so:

  • person_properties={} was inconclusive and fell back to /flags (correct);
  • person_properties={"created_at": "2026-06-01"} returned a local answer from that value, which can disagree with /flags for teams that set their own created_at person property.

Following the fix the issue suggests (and what posthog-dotnet already does), a filter type that local evaluation can't evaluate is unsupported:

  • _match_condition_filter now matches only person and group filters (or one without a type) against the caller's properties. cohort and flag filters keep their own matching. Any other type raises _RequiresServerFilter, a private RequiresServerEvaluation with unsupported_definition, so a later condition can't decide the flag. This covers flag conditions and cohort criteria, which both go through it.
  • match_property_group holds that error back while another filter can still decide the cohort (AND with a mismatch, OR with a match), as the spec's three-valued composition requires, and raises it when the cohort stays undecided. Missing cohorts and malformed groups still raise at once.
  • _is_unsupported_property applies the same rule, so the definition check marks such a flag unsupported_definition when definitions load.
  • The load-time warning and the UNSUPPORTED_DEFINITION docstring mention filter types.
  • The public match_property is unchanged.

The same change for posthog-node is PostHog/posthog-js#5840.

💚 How did you test it?

New posthog/test/test_feature_flags_person_metadata.py, through Client.evaluate_flags:

Case Expected
person_metadata filter in a cohort, caller passes created_at falls back to /flags and returns its answer
person_metadata filter directly in a flag condition falls back to /flags
only_evaluate_locally=True, with and without created_at, and with negation or not_in unresolved, unsupported_definition, no /flags call
loading the definitions logs the unsupported_definition warning
a later condition with another variant, an early_exit exclusion, or a dependent flag falls back to /flags
another filter in the condition that does not match False locally
another filter that decides an AND or OR cohort, also with not_in, in either order, with the filter nested, in another cohort or behind a flag dependency decided locally, no /flags call
a cohort that stays undecided, with a later condition falls back to /flags
several causes in one cohort, one condition or several conditions the highest-precedence reason
a person or untyped filter on created_at, or a group filter still evaluated locally

Reverting any one part of the change (the error type, the deferral, the dependency's error type, the definition check) makes some of these fail.

  • The whole posthog/test tree with the test extra, on Windows: 8938 passed, 41 skipped, 16 failed. 14 of them fail on the base commit too: fork hooks, path separators, and a digest of vendored fixtures. The other two are timing-dependent here: one also fails without this commit, the other passes when run alone.
  • End to end: a Posthog client against a local HTTP server that serves the definitions and /flags, with an AND cohort of a plan filter and First seen. It answers locally for a person the plan rules out, and makes exactly one /flags request otherwise.
  • ruff format --check is clean. ruff check reports nothing in the new test file and nothing new in feature_flags.py.

📝 Checklist

  • All commits are signed (see Commit signing)
  • I reviewed the submitted code.
  • I added tests to verify the changes.
  • I updated the docs if needed.
  • No breaking change or entry added to the changelog.

If releasing new changes

  • Ran sampo add to generate a changeset file

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

  • Written with Claude Code. The account owner asked for fixes to open PostHog SDK issues, and the agent picked this one. The owner has reviewed the full diff at 19000d3.
  • I used an allow-list (person, group) instead of special-casing person_metadata, so a filter type added on the server later also falls back instead of being matched as a person property.

🤖 Generated with Claude Code

…ties

A cohort can filter on Person metadata > First seen
(type "person_metadata", key "created_at"). /flags reads that value
from the persons table and ignores any created_at person property.
Local evaluation treated every filter type other than cohort and flag
as a person property, so a caller passing created_at got an answer
based on that value, which could disagree with /flags.

Only person and group filters are now matched against the properties
the caller passes. Any other type is unsupported_definition: the
definition check flags it when definitions load, and evaluation falls
back to /flags (or stays unresolved with only_evaluate_locally).
match_property itself is unchanged.

Part of PostHog/posthog#137503 (posthog-python)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@dustinbyrne dustinbyrne left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The runtime change in posthog/feature_flags.py looks minimal and matches both /flags (person_metadata reads from the persons table rather than person properties) and posthog-dotnet's allow-list approach for unsupported property filter types.

There are two test concerns inline before approval:

  1. The new _is_unsupported_property check (posthog/feature_flags.py:1862) has no test coverage, and the new test file only exercises the deprecated get_feature_flag path.
  2. TestPersonMetadataFilters._client constructs live Client(..., send=True) instances without client.shutdown(), leaking background Consumer threads that attempt outbound capture POSTs during longer test runs.

Outside the scope of this PR (non-blocking follow-ups): codifying the property filter type allow-list in PostHog/sdk-specs, aligning remaining peer server SDKs and the posthog.com local-evaluation restrictions docs, and evaluating separately whether sdk-specs should address multi-condition multivariate / early_exit catch-all fallthrough after an inconclusive condition.

AI-assisted review.

Comment thread posthog/feature_flags.py Resolved
@dustinbyrne
dustinbyrne requested a review from a team November 23, 2026 21:43
The error let later conditions decide the flag. Only /flags knows the value,
so treat it like a static cohort. Also cover the load-time warning,
evaluate_flags and negation, with a client that sends nothing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@dustinbyrne dustinbyrne left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for updating the tests and fixing the test client cleanup — both concerns from the earlier review (_load_feature_flags() / evaluate_flags() / unresolved_flags / negation & negative-control coverage, and send=False + client.shutdown()) are addressed cleanly.

One Breaking regression remains inline on posthog/feature_flags.py before approval: switching _assert_property_filter_type_supported to raise RequiresServerEvaluation breaks three-valued AND/OR short-circuiting in match_property_group for dynamic cohorts that combine person_metadata with another filter (affecting both AND — including not_in — and OR cohorts, regressing merge-base behavior when created_at is omitted, and diverging from sdk-specs).

Optional Suggestion (non-blocking, outside the current diff): consider adding "an unsupported filter type" to the example list in the load-time unsupported_definition warning (posthog/client.py:4280-4288) and UnresolvedFlagReason.UNSUPPORTED_DEFINITION docstring (posthog/types.py:130-133) so operators seeing the warning for a dynamic cohort with a First seen filter can diagnose it directly.

(Outside this PR's scope as non-blocking follow-ups: pre-existing filter-order handling in _match_condition_properties at posthog/feature_flags.py:928 matches test_static_cohort_after_unchecked_filter_lets_later_conditions_resolve and peer SDKs; documenting person_metadata restrictions in PostHog/posthog.com and codifying unsupported filter types in PostHog/sdk-specs.)

AI-assisted review.

Comment thread posthog/feature_flags.py Resolved
@dustinbyrne
dustinbyrne requested a review from a team November 24, 2026 20:20
A cohort stopped at the first filter that only the server can check, even when
another filter had already decided it. Raise the error only when the cohort
stays undecided.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@dustinbyrne dustinbyrne left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fast follow-up in 07ee9f6 — the _RequiresServerFilter deferral cleanly resolves the dynamic-cohort three-valued AND/OR regression (all 9 decisive-sibling regression cases now pass on 07ee9f6, alongside all 21 new tests and 1530 flag tests), and the warning/docstring updates look great.

One narrow Concern remains inline on posthog/feature_flags.py before approval: deferring _RequiresServerFilter in match_property_group drops higher-precedence UnresolvedFlagReason values (UNSUPPORTED_DEFINITION lost to UNRESOLVED_DEPENDENCY), with the same precedence drop amplified at _raise_condition_errors:960-961 and _match_flag_conditions:633-641. There is also one optional Suggestion inline on posthog/test/test_feature_flags_person_metadata.py.

(Outside this PR's scope as non-blocking follow-ups: documenting person_metadata / unsupported filter types in PostHog/posthog.com's local-evaluation restrictions, codifying them in PostHog/sdk-specs, and aligning peer server SDKs under PostHog/posthog#137503.)

AI-assisted review.

Comment thread posthog/feature_flags.py Resolved
@dustinbyrne
dustinbyrne requested a review from a team November 24, 2026 21:34
…lter

An error that only the server can resolve kept its own reason, so a flag with
a runtime unsupported_definition filter could be reported as
unresolved_dependency. The reasons are now merged in the cohort group, in the
condition and across conditions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

SDK performance: posthog-python

Benchmarks completed. No changes flagged for review.

Flags require at least a 5% change in the median and all six pairs agreeing on direction. This is a noise filter, not proof of a performance change or a CI gate.

View all results
Test Measurement Before PR With PR Change Assessment
Capture and deliver events (32-byte payload, burst)
Shard: capture
Managed heap after settling — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​; head:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Managed heap after settling — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​; head:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​
Capture and deliver events (32-byte payload, steady)
Shard: capture
Managed heap after settling — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​; head:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Managed heap after settling — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​; head:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​
Queue an event (32-byte payload)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​; head:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​
Queue an event (32-byte payload)
Shard: capture
Allocations per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​; head:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​
Queue an event (4,096-byte payload)
Shard: capture
Allocated memory per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​; head:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​
Queue an event (4,096-byte payload)
Shard: capture
Allocations per operation — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​; head:​ Background preparation has no public completion boundary before flush; see capture.​drain for full-pipeline allocations.​
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Managed heap after settling — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​; head:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​
Refresh 1,000 flag definitions
Shard: flags-memory
Managed heap after settling — — — unavailable; base:​ unsupported; head:​ unsupported; base:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​; head:​ CPython has no uninstrumented total managed-heap byte counter; tracing would distort this RSS pass.​
Capture and deliver events (32-byte payload, burst)
Shard: capture
Allocated memory per operation 133.67 KiB/op 133.67 KiB/op No observed change Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Allocations per operation 1,345.51 count/op 1,345.51 count/op No observed change Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Time per operation 76.32 µs/op 76.41 µs/op 0.1% more time Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Idle process memory (RSS) 37.66 MiB 37.61 MiB 0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Observed peak process memory (RSS) 40.11 MiB 40.06 MiB 0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Process memory after settling (RSS) 40.11 MiB 40.06 MiB 0.1% less memory Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Process CPU time per operation 80.42 µs/op 80.32 µs/op 0.1% less time Not flagged
Capture and deliver events (32-byte payload, burst)
Shard: capture
Lifetime peak process memory (RSS) 40.36 MiB 40.36 MiB No observed change Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Allocated memory per operation 185.75 KiB/op 185.75 KiB/op <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Allocations per operation 1,337.51 count/op 1,337.51 count/op <0.1% more Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Time per operation 99.58 µs/op 99.33 µs/op 0.3% less time Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Idle process memory (RSS) 41.21 MiB 41.24 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Observed peak process memory (RSS) 47 MiB 47.02 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Process memory after settling (RSS) 47 MiB 47.02 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Process CPU time per operation 97.47 µs/op 97.21 µs/op 0.3% less time Not flagged
Capture and deliver events (4,096-byte payload, burst)
Shard: capture
Lifetime peak process memory (RSS) 51.43 MiB 51.46 MiB <0.1% more memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Allocated memory per operation 138.73 KiB/op 138.73 KiB/op <0.1% more memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Allocations per operation 1,390.29 count/op 1,390.3 count/op <0.1% more Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Time per operation 88.28 µs/op 88.34 µs/op <0.1% more time Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Idle process memory (RSS) 37.52 MiB 37.62 MiB 0.3% more memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Observed peak process memory (RSS) 37.69 MiB 37.78 MiB 0.2% more memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Process memory after settling (RSS) 37.69 MiB 37.78 MiB 0.2% more memory Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Process CPU time per operation 90.35 µs/op 90.07 µs/op 0.3% less time Not flagged
Capture and deliver events (32-byte payload, steady)
Shard: capture
Lifetime peak process memory (RSS) 40.36 MiB 40.36 MiB No observed change Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Allocated memory per operation 190.9 KiB/op 190.9 KiB/op No observed change Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Allocations per operation 1,382.19 count/op 1,382.19 count/op No observed change Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Time per operation 105.47 µs/op 104.43 µs/op 1% less time Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Idle process memory (RSS) 41.07 MiB 41.12 MiB 0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Observed peak process memory (RSS) 41.53 MiB 41.57 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Process memory after settling (RSS) 41.13 MiB 41.17 MiB <0.1% more memory Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Process CPU time per operation 102.65 µs/op 100.92 µs/op 1.7% less time Not flagged
Capture and deliver events (4,096-byte payload, steady)
Shard: capture
Lifetime peak process memory (RSS) 41.49 MiB 41.5 MiB <0.1% more memory Not flagged
Queue an event (32-byte payload)
Shard: capture
Caller-thread CPU time per operation 56.99 µs/op 56.77 µs/op 0.4% less time Not flagged
Queue an event (32-byte payload)
Shard: capture
Time per operation 57.15 µs/op 56.77 µs/op 0.7% less time Not flagged
Queue an event (4,096-byte payload)
Shard: capture
Caller-thread CPU time per operation 56.87 µs/op 57.03 µs/op 0.3% more time Not flagged
Queue an event (4,096-byte payload)
Shard: capture
Time per operation 56.97 µs/op 57.03 µs/op <0.1% more time Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Allocated memory per operation 225.43 KiB/op 234.05 KiB/op 3.8% more memory Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Allocations per operation 2,279.42 count/op 2,352.93 count/op 3.2% more Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Time per operation 137.84 µs/op 141.69 µs/op 2.8% more time Not flagged
Evaluate all 10 flags
Shard: flags-scaling
Process CPU time per operation 137.83 µs/op 141.68 µs/op 2.8% more time Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Allocated memory per operation 2.17 MiB/op 2.25 MiB/op 3.9% more memory Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Allocations per operation 22,413.69 count/op 23,148.75 count/op 3.3% more Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Time per operation 1.3 ms/op 1.33 ms/op 2% more time Not flagged
Evaluate all 100 flags
Shard: flags-scaling
Process CPU time per operation 1.3 ms/op 1.33 ms/op 2% more time Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Allocated memory per operation 21.63 MiB/op 22.47 MiB/op 3.9% more memory Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Allocations per operation 223,655.44 count/op 231,005.5 count/op 3.3% more Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Time per operation 12.73 ms/op 12.95 ms/op 1.7% more time Not flagged
Evaluate all 1,000 flags
Shard: flags-scaling
Process CPU time per operation 12.73 ms/op 12.95 ms/op 1.7% more time Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Idle process memory (RSS) 43.87 MiB 43.81 MiB 0.2% less memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Observed peak process memory (RSS) 44.18 MiB 44.15 MiB <0.1% less memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Process memory after settling (RSS) 44.18 MiB 44.15 MiB <0.1% less memory Not flagged
Evaluate 1,000 flags under concurrent load
Shard: flags-memory
Lifetime peak process memory (RSS) 43.92 MiB 43.9 MiB <0.1% less memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Idle process memory (RSS) 42.98 MiB 42.98 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Observed peak process memory (RSS) 42.99 MiB 42.99 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Process memory after settling (RSS) 42.99 MiB 42.99 MiB <0.1% more memory Not flagged
Refresh 1,000 flag definitions
Shard: flags-memory
Lifetime peak process memory (RSS) 42.77 MiB 43.28 MiB 1.2% more memory Not flagged
Evaluate one boolean flag
Shard: flags-single
Allocated memory per operation 15.74 KiB/op 15.74 KiB/op No observed change Not flagged
Evaluate one boolean flag
Shard: flags-single
Allocations per operation 162.77 count/op 162.77 count/op No observed change Not flagged
Evaluate one boolean flag
Shard: flags-single
Time per operation 7.22 µs/op 7.18 µs/op 0.5% less time Not flagged
Evaluate one boolean flag
Shard: flags-single
Process CPU time per operation 7.22 µs/op 7.18 µs/op 0.5% less time Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Allocated memory per operation 24.6 KiB/op 25.31 KiB/op 2.9% more memory Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Allocations per operation 239.28 count/op 245.28 count/op 2.5% more Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Time per operation 9.63 µs/op 9.91 µs/op 3% more time Not flagged
Evaluate a cohort-filtered flag
Shard: flags-single
Process CPU time per operation 9.63 µs/op 9.91 µs/op 3% more time Not flagged
Evaluate a flag (early match)
Shard: flags-single
Allocated memory per operation 39.81 KiB/op 41.4 KiB/op 4% more memory Not flagged
Evaluate a flag (early match)
Shard: flags-single
Allocations per operation 388.27 count/op 401.77 count/op 3.5% more Not flagged
Evaluate a flag (early match)
Shard: flags-single
Time per operation 13.93 µs/op 13.99 µs/op 0.5% more time Not flagged
Evaluate a flag (early match)
Shard: flags-single
Process CPU time per operation 13.93 µs/op 14 µs/op 0.5% more time Not flagged
Evaluate a flag (late match)
Shard: flags-single
Allocated memory per operation 60.59 KiB/op 63.4 KiB/op 4.6% more memory Not flagged
Evaluate a flag (late match)
Shard: flags-single
Allocations per operation 584.27 count/op 608.27 count/op 4.1% more Not flagged
Evaluate a flag (late match)
Shard: flags-single
Time per operation 19.78 µs/op 20.15 µs/op 1.9% more time Not flagged
Evaluate a flag (late match)
Shard: flags-single
Process CPU time per operation 19.78 µs/op 20.15 µs/op 1.9% more time Not flagged
Evaluate a flag (no match)
Shard: flags-single
Allocated memory per operation 59.22 KiB/op 62.03 KiB/op 4.7% more memory Not flagged
Evaluate a flag (no match)
Shard: flags-single
Allocations per operation 567.77 count/op 591.77 count/op 4.2% more Not flagged
Evaluate a flag (no match)
Shard: flags-single
Time per operation 18.46 µs/op 19.14 µs/op 3.7% more time Not flagged
Evaluate a flag (no match)
Shard: flags-single
Process CPU time per operation 18.46 µs/op 19.14 µs/op 3.7% more time Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Allocated memory per operation 19.04 KiB/op 19.39 KiB/op 1.8% more memory Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Allocations per operation 192.27 count/op 195.27 count/op 1.6% more Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Time per operation 7.8 µs/op 8.12 µs/op 4.2% more time Not flagged
Evaluate a property-filtered flag
Shard: flags-single
Process CPU time per operation 7.8 µs/op 8.12 µs/op 4.2% more time Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Allocated memory per operation 20.66 KiB/op 21.02 KiB/op 1.7% more memory Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Allocations per operation 197.77 count/op 200.77 count/op 1.5% more Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Time per operation 8.63 µs/op 8.76 µs/op 1.5% more time Not flagged
Evaluate a regex-filtered flag
Shard: flags-single
Process CPU time per operation 8.63 µs/op 8.76 µs/op 1.5% more time Not flagged
Evaluate a rollout flag
Shard: flags-single
Allocated memory per operation 14.89 KiB/op 14.89 KiB/op No observed change Not flagged
Evaluate a rollout flag
Shard: flags-single
Allocations per operation 152.77 count/op 152.77 count/op No observed change Not flagged
Evaluate a rollout flag
Shard: flags-single
Time per operation 6.45 µs/op 6.54 µs/op 1.4% more time Not flagged
Evaluate a rollout flag
Shard: flags-single
Process CPU time per operation 6.45 µs/op 6.54 µs/op 1.4% more time Not flagged
Evaluate a multivariate flag
Shard: flags-single
Allocated memory per operation 15.9 KiB/op 15.9 KiB/op No observed change Not flagged
Evaluate a multivariate flag
Shard: flags-single
Allocations per operation 166.77 count/op 166.77 count/op No observed change Not flagged
Evaluate a multivariate flag
Shard: flags-single
Time per operation 7.34 µs/op 7.3 µs/op 0.6% less time Not flagged
Evaluate a multivariate flag
Shard: flags-single
Process CPU time per operation 7.34 µs/op 7.3 µs/op 0.6% less time Not flagged

Values are medians of paired measurements. Not flagged does not mean unchanged. Unavailable means a measurement could not be provided, not zero. Estimated allocation measurements retain their instrumentation uncertainty. RSS measures the whole process, not just SDK allocations; observed peaks are sampled checkpoints. Paired ranges in the diagnostics describe variability, not confidence intervals.

Each shard uses its own runner; compare Before PR against With PR within a row, not across shards.

Compared 84fc9e06bd898fe090e7443138e32010b9aa91db → 19000d370fbf104568f45ee163aa1fe1bbd33820.

Full report and diagnostics

102 metric rows; 102 rows shown in all results. Omitted or shortened data remain in comparison.json, including per-runner environments, resource limits, measurement methods, samples and checkpoints.

@marandaneto

Copy link
Copy Markdown
Member

lemme confirm PostHog/sdk-specs#251 before merging

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants